IDENT	[a-zA-Z][a-zA-Z0-9_]*
INT 	[0-9]
MASK    [01.]
SPACE   [ \t\n\r]*

%%

{INT}+      {addParam(yytext);return T_INT;}
"("	{return T_OPEN_PAR;}
")"	{return T_CLOSE_PAR;}
";"	{return T_PONTVIRG;}
":"	{return T_DOISPONTOS;}
"DEVC"	{return T_DEVC;}
"{"	{return T_OPEN_CHAVE;}
"}"	{return T_CLOSE_CHAVE;}
"="	{return T_IGUAL;}
"\""	{return T_ASPAS;}
"'"	{return T_ASPA;}
"%"	{return T_PERCENT;}
"%RESERVED"	{return T_PERCENT_RESERVED;}
"%MASK"	{return T_PERCENT_MASK;}
"s"	{return T_S;}
"r"	{return T_R;}
"."	{return T_DOT;}
{MASK}{8}       {addParam(yytext);return T_MASKREP;}
"dc_scml_port"	{return T_DC_SCML_PORT;}
"dc_tlm_port"	{return T_DC_TLM_PORT;}
"dc_clk_port"	{return T_DC_CLK_PORT;}
"dc_format"	{return T_DC_FORMAT;}
"dc_service"	{return T_DC_SERVICE;}
">"	{addParam(">");return T_MAIOR;}
"<"	{addParam("<");return T_MENOR;}
","	{return T_VIRG;}
"READ"	{return T_READ;}
"WRITE"	{return T_WRITE;}
"dc_reg"	{return T_DC_REG;}
"dc_buffer"	{return T_DC_BUFFER;}
"dc_drv_map"	{return T_DC_DRV_MAP;}
"dc_os"	{return T_DC_OS;}
"dc_os_map"	{return T_DC_OS_MAP;}
"OPEN"	{return T_OPEN;}
"INIT"	{return T_INIT;}
"RELEASE"	{return T_RELEASE;}
"CLOSE"	{return T_CLOSE;}
"IOCTL"	{return T_IOCTL;}
"SEEK"	{return T_SEEK;}
"DEV_CTOR"	{return T_DEV_CTOR;}
"set_address"	{return T_SET_ADDRESS;}
"bindTo"	{return T_BINDTO;}
"set_actions"	{return T_SET_ACTION;}
"pre"	{return T_PRE;}
"pos"	{return T_POS;}
"wait_state"	{return T_WAIT_STATE;}
"interrupt"	{return T_INTERRUPT;}
"polling"	{return T_POLLING;}
"=="    {addParam("==");return T_OPER;}
"!="    {addParam("!=");return T_OPER;}
"<="    {addParam("<=");return T_OPER;}
">="	{addParam(">=");return T_OPER;}
"+"	{return T_PLUS;}
"uclinux"	{return T_UCLINUX;}
{IDENT}     {addParam(yytext);return T_IDENT;}
{SPACE}     {            }
.           {            }
%%
